﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Galoap
{
    class ColorCategory : Category
    {
        private string [] Exadecimal;

        public ColorCategory()
        {
            PluralCategoryName = "colori";
            SingularCategoryName = "colore";
            CategoryAttributes = new string[] {
                "giallo", "rosso", "verde", "nero", "grigio", "blu", "bianco", "viola", "arancio", "azzurro" 
            };
            Exadecimal = new string[] {
                "#ffff00", "#ff0000", "#40ff00", "#000000", "#808080", "#2000c0", "#ffffff", "#a000c0", "#ff8000", "#00a0ff"
            };
        }

        public string GetColorCode(string colorname)
        {
            for (int i = 0; i < CategoryAttributes.Length; i++)
                if (CategoryAttributes[i].Equals(colorname))
                    return Exadecimal[i];
            return "";
        }


    }
}
